package cn.tkd.client.gold;


/**
 * @author 嘉陵江里捉鱼 email:tang7259@163.com
 *@version 1.0
 *@time Nov 18, 2008 1:43:11 PM
 */
public class Screen {

    private static AppConfig appConfig;

    public static native int getScreenWidth() /*-{
                                                 return screen.width;

                                              }-*/;

    public static native int getScreenHeight() /*-{
                                              return screen.height;

                                           }-*/;

    public static AppConfig getAppConfig() {
        if (appConfig == null) {
            // appConfig = AppConfig.getDefaultAppConfig();
            // int width = Screen.getScreenWidth();
            // int height = Screen.getScreenHeight();
            // if (width == 1024 && height == 768) {
            // appConfig = AppConfig.getDefaultAppConfig();
            // } else if (width == 1680 && height == 1050) {
            // appConfig = AppConfig.get1680AppConfig();
            // }
            appConfig = AppConfig.getDefaultAppConfig();
        }
        return appConfig;
    }
}
